<?xml version="1.0" encoding="ascii"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
          "DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
  <title>pln_inco.temantex.VinculacionFreelingEventos</title>
  <link rel="stylesheet" href="epydoc.css" type="text/css" />
  <script type="text/javascript" src="epydoc.js"></script>
</head>

<body bgcolor="white" text="black" link="blue" vlink="#204080"
      alink="#204080">
<!-- ==================== NAVIGATION BAR ==================== -->
<table class="navbar" border="0" width="100%" cellpadding="0"
       bgcolor="#a0c0ff" cellspacing="0">
  <tr valign="middle">

  <!-- Tree link -->
      <th>&nbsp;&nbsp;&nbsp;<a
        href="module-tree.html">Trees</a>&nbsp;&nbsp;&nbsp;</th>

  <!-- Index link -->
      <th>&nbsp;&nbsp;&nbsp;<a
        href="identifier-index.html">Indices</a>&nbsp;&nbsp;&nbsp;</th>

  <!-- Help link -->
      <th>&nbsp;&nbsp;&nbsp;<a
        href="help.html">Help</a>&nbsp;&nbsp;&nbsp;</th>

  <!-- Project homepage -->
      <th class="navbar" align="right" width="100%">
        <table border="0" cellpadding="0" cellspacing="0">
          <tr><th class="navbar" align="center"
            >alan</th>
          </tr></table></th>
  </tr>
</table>
<table width="100%" cellpadding="0" cellspacing="0">
  <tr valign="top">
    <td width="100%">
      <span class="breadcrumbs">
        Package&nbsp;pln_inco ::
        Package&nbsp;temantex ::
        Module&nbsp;VinculacionFreelingEventos
      </span>
    </td>
    <td>
      <table cellpadding="0" cellspacing="0">
        <!-- hide/show private -->
        <tr><td align="right"><span class="options">[<a href="javascript:void(0);" class="privatelink"
    onclick="toggle_private();">hide&nbsp;private</a>]</span></td></tr>
        <tr><td align="right"><span class="options"
            >[<a href="frames.html" target="_top">frames</a
            >]&nbsp;|&nbsp;<a href="pln_inco.temantex.VinculacionFreelingEventos-module.html"
            target="_top">no&nbsp;frames</a>]</span></td></tr>
      </table>
    </td>
  </tr>
</table>
<!-- ==================== MODULE DESCRIPTION ==================== -->
<h1 class="epydoc">Module VinculacionFreelingEventos</h1><p class="nomargin-top"><span class="codelink"><a href="pln_inco.temantex.VinculacionFreelingEventos-pysrc.html">source&nbsp;code</a></span></p>
<!-- ==================== FUNCTIONS ==================== -->
<a name="section-Functions"></a>
<table class="summary" border="1" cellpadding="3"
       cellspacing="0" width="100%" bgcolor="white">
<tr bgcolor="#70b0f0" class="table-header">
  <td colspan="2" class="table-header">
    <table border="0" cellpadding="0" cellspacing="0" width="100%">
      <tr valign="top">
        <td align="left"><span class="table-header">Functions</span></td>
        <td align="right" valign="top"
         ><span class="options">[<a href="#section-Functions"
         class="privatelink" onclick="toggle_private();"
         >hide private</a>]</span></td>
      </tr>
    </table>
  </td>
</tr>
<tr class="private">
    <td width="15%" align="right" valign="top" class="summary">
      <span class="summary-type">&nbsp;</span>
    </td><td class="summary">
      <table width="100%" cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td><span class="summary-sig"><a href="pln_inco.temantex.VinculacionFreelingEventos-module.html#cargarAnotacionesEventos" class="summary-sig-name" onclick="show_private();">cargarAnotacionesEventos</a>(<span class="summary-sig-arg">text_file</span>,
        <span class="summary-sig-arg">encoding_text_file</span>,
        <span class="summary-sig-arg">annotations_file</span>)</span><br />
      Retorna una lista de pares (TokenTexto, [anotaci&#243;n]) donde la segunda
      componente es vac&#237;a si el token no tiene anotaciones.</td>
          <td align="right" valign="top">
            <span class="codelink"><a href="pln_inco.temantex.VinculacionFreelingEventos-pysrc.html#cargarAnotacionesEventos">source&nbsp;code</a></span>
            
          </td>
        </tr>
      </table>
      
    </td>
  </tr>
<tr class="private">
    <td width="15%" align="right" valign="top" class="summary">
      <span class="summary-type">&nbsp;</span>
    </td><td class="summary">
      <table width="100%" cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td><span class="summary-sig"><a href="pln_inco.temantex.VinculacionFreelingEventos-module.html#quedarseConUnaAnotacion" class="summary-sig-name" onclick="show_private();">quedarseConUnaAnotacion</a>(<span class="summary-sig-arg">lista_tokens_anotaciones</span>)</span><br />
      Antes de combinar con la salida de Freeling, le damos una pasada a 
      nuestra lista de tokens para que cada token quede con exactamente una
      anotaci&#243;n.</td>
          <td align="right" valign="top">
            <span class="codelink"><a href="pln_inco.temantex.VinculacionFreelingEventos-pysrc.html#quedarseConUnaAnotacion">source&nbsp;code</a></span>
            
          </td>
        </tr>
      </table>
      
    </td>
  </tr>
<tr class="private">
    <td width="15%" align="right" valign="top" class="summary">
      <span class="summary-type">&nbsp;</span>
    </td><td class="summary">
      <table width="100%" cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td><span class="summary-sig"><a href="pln_inco.temantex.VinculacionFreelingEventos-module.html#mergeFreelingConAnotaciones" class="summary-sig-name" onclick="show_private();">mergeFreelingConAnotaciones</a>(<span class="summary-sig-arg">text_file</span>,
        <span class="summary-sig-arg">encoding_text_file</span>,
        <span class="summary-sig-arg">annotations_file</span>)</span><br />
      Combina las anotaciones del xml de knowtator con la salida del 
      etiquetado gramatical de Freeling</td>
          <td align="right" valign="top">
            <span class="codelink"><a href="pln_inco.temantex.VinculacionFreelingEventos-pysrc.html#mergeFreelingConAnotaciones">source&nbsp;code</a></span>
            
          </td>
        </tr>
      </table>
      
    </td>
  </tr>
<tr class="private">
    <td width="15%" align="right" valign="top" class="summary">
      <span class="summary-type">&nbsp;</span>
    </td><td class="summary">
      <table width="100%" cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td><span class="summary-sig"><a name="getValorAtributo"></a><span class="summary-sig-name">getValorAtributo</span>(<span class="summary-sig-arg">anotacion</span>,
        <span class="summary-sig-arg">nom_atributo</span>)</span></td>
          <td align="right" valign="top">
            <span class="codelink"><a href="pln_inco.temantex.VinculacionFreelingEventos-pysrc.html#getValorAtributo">source&nbsp;code</a></span>
            
          </td>
        </tr>
      </table>
      
    </td>
  </tr>
<tr>
    <td width="15%" align="right" valign="top" class="summary">
      <span class="summary-type">&nbsp;</span>
    </td><td class="summary">
      <table width="100%" cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td><span class="summary-sig"><a href="pln_inco.temantex.VinculacionFreelingEventos-module.html#obtenerOracionesTokensEtiquetados" class="summary-sig-name">obtenerOracionesTokensEtiquetados</a>(<span class="summary-sig-arg">text_file</span>,
        <span class="summary-sig-arg">encoding_text_file</span>,
        <span class="summary-sig-arg">annotations_file</span>)</span><br />
      Misma salida que mergeFreelingConAnotaciones(), con la salvedad de que se elimina
la clave 'anotacion' y pasa a ser 'tag_evento'.</td>
          <td align="right" valign="top">
            <span class="codelink"><a href="pln_inco.temantex.VinculacionFreelingEventos-pysrc.html#obtenerOracionesTokensEtiquetados">source&nbsp;code</a></span>
            
          </td>
        </tr>
      </table>
      
    </td>
  </tr>
</table>
<!-- ==================== VARIABLES ==================== -->
<a name="section-Variables"></a>
<table class="summary" border="1" cellpadding="3"
       cellspacing="0" width="100%" bgcolor="white">
<tr bgcolor="#70b0f0" class="table-header">
  <td colspan="2" class="table-header">
    <table border="0" cellpadding="0" cellspacing="0" width="100%">
      <tr valign="top">
        <td align="left"><span class="table-header">Variables</span></td>
        <td align="right" valign="top"
         ><span class="options">[<a href="#section-Variables"
         class="privatelink" onclick="toggle_private();"
         >hide private</a>]</span></td>
      </tr>
    </table>
  </td>
</tr>
<tr class="private">
    <td width="15%" align="right" valign="top" class="summary">
      <span class="summary-type">&nbsp;</span>
    </td><td class="summary">
        <a name="__package__"></a><span class="summary-name">__package__</span> = <code title="'pln_inco.temantex'"><code class="variable-quote">'</code><code class="variable-string">pln_inco.temantex</code><code class="variable-quote">'</code></code>
    </td>
  </tr>
</table>
<!-- ==================== FUNCTION DETAILS ==================== -->
<a name="section-FunctionDetails"></a>
<table class="details" border="1" cellpadding="3"
       cellspacing="0" width="100%" bgcolor="white">
<tr bgcolor="#70b0f0" class="table-header">
  <td colspan="2" class="table-header">
    <table border="0" cellpadding="0" cellspacing="0" width="100%">
      <tr valign="top">
        <td align="left"><span class="table-header">Function Details</span></td>
        <td align="right" valign="top"
         ><span class="options">[<a href="#section-FunctionDetails"
         class="privatelink" onclick="toggle_private();"
         >hide private</a>]</span></td>
      </tr>
    </table>
  </td>
</tr>
</table>
<a name="cargarAnotacionesEventos"></a>
<div class="private">
<table class="details" border="1" cellpadding="3"
       cellspacing="0" width="100%" bgcolor="white">
<tr><td>
  <table width="100%" cellpadding="0" cellspacing="0" border="0">
  <tr valign="top"><td>
  <h3 class="epydoc"><span class="sig"><span class="sig-name">cargarAnotacionesEventos</span>(<span class="sig-arg">text_file</span>,
        <span class="sig-arg">encoding_text_file</span>,
        <span class="sig-arg">annotations_file</span>)</span>
  </h3>
  </td><td align="right" valign="top"
    ><span class="codelink"><a href="pln_inco.temantex.VinculacionFreelingEventos-pysrc.html#cargarAnotacionesEventos">source&nbsp;code</a></span>&nbsp;
    </td>
  </tr></table>
  
  <p>Retorna una lista de pares (TokenTexto, [anotaci&#243;n]) donde la segunda 
  componente es vac&#237;a si el token no tiene anotaciones. De lo contrario, la
  misma es la lista de anotaciones asociadas al token.</p>
  <p>Salvo pocas excepciones, como las palabras anotadas como INTRUSO (que 
  est&#225;n dentro de un evento), la lista de anotaciones tendr&#225; solo un 
  elemento.</p>
  <dl class="fields">
  </dl>
</td></tr></table>
</div>
<a name="quedarseConUnaAnotacion"></a>
<div class="private">
<table class="details" border="1" cellpadding="3"
       cellspacing="0" width="100%" bgcolor="white">
<tr><td>
  <table width="100%" cellpadding="0" cellspacing="0" border="0">
  <tr valign="top"><td>
  <h3 class="epydoc"><span class="sig"><span class="sig-name">quedarseConUnaAnotacion</span>(<span class="sig-arg">lista_tokens_anotaciones</span>)</span>
  </h3>
  </td><td align="right" valign="top"
    ><span class="codelink"><a href="pln_inco.temantex.VinculacionFreelingEventos-pysrc.html#quedarseConUnaAnotacion">source&nbsp;code</a></span>&nbsp;
    </td>
  </tr></table>
  
  <p>Antes de combinar con la salida de Freeling, le damos una pasada a 
  nuestra lista de tokens para que cada token quede con exactamente una 
  anotaci&#243;n.</p>
  <p>El &#250;nico caso para el que sirve esto es para los &quot;intrusos&quot;,
  de forma que la etiqueta &quot;intruso&quot; le gane a 
  &quot;evento&quot;.</p>
  <dl class="fields">
  </dl>
</td></tr></table>
</div>
<a name="mergeFreelingConAnotaciones"></a>
<div class="private">
<table class="details" border="1" cellpadding="3"
       cellspacing="0" width="100%" bgcolor="white">
<tr><td>
  <table width="100%" cellpadding="0" cellspacing="0" border="0">
  <tr valign="top"><td>
  <h3 class="epydoc"><span class="sig"><span class="sig-name">mergeFreelingConAnotaciones</span>(<span class="sig-arg">text_file</span>,
        <span class="sig-arg">encoding_text_file</span>,
        <span class="sig-arg">annotations_file</span>)</span>
  </h3>
  </td><td align="right" valign="top"
    ><span class="codelink"><a href="pln_inco.temantex.VinculacionFreelingEventos-pysrc.html#mergeFreelingConAnotaciones">source&nbsp;code</a></span>&nbsp;
    </td>
  </tr></table>
  
  <p>Combina las anotaciones del xml de knowtator con la salida del 
  etiquetado gramatical de Freeling</p>
  <p>Devuelve una lista de oraciones, siendo cada elemento de &#233;sta una 
  lista de tipo [(TokenTexto, diccionario)], donde los tokens corresponden 
  a los de Freeling, y diccionario tiene la informaci&#243;n que brindaba 
  Freeling, adem&#225;s de la anotaci&#243;n en la clave 'anotacion'.</p>
  <dl class="fields">
  </dl>
</td></tr></table>
</div>
<a name="obtenerOracionesTokensEtiquetados"></a>
<div>
<table class="details" border="1" cellpadding="3"
       cellspacing="0" width="100%" bgcolor="white">
<tr><td>
  <table width="100%" cellpadding="0" cellspacing="0" border="0">
  <tr valign="top"><td>
  <h3 class="epydoc"><span class="sig"><span class="sig-name">obtenerOracionesTokensEtiquetados</span>(<span class="sig-arg">text_file</span>,
        <span class="sig-arg">encoding_text_file</span>,
        <span class="sig-arg">annotations_file</span>)</span>
  </h3>
  </td><td align="right" valign="top"
    ><span class="codelink"><a href="pln_inco.temantex.VinculacionFreelingEventos-pysrc.html#obtenerOracionesTokensEtiquetados">source&nbsp;code</a></span>&nbsp;
    </td>
  </tr></table>
  
  <pre class="literalblock">
Misma salida que mergeFreelingConAnotaciones(), con la salvedad de que se elimina
la clave 'anotacion' y pasa a ser 'tag_evento'.

Finalmente entonces se devuelve una lista de tuplas (tag, diccionario) donde diccionario
tiene claves {token, lema_freeling,     tag_freeling, tag_evento}.
El elemento diccionario['token'] es de tipo TokenTexto, corresponde a un token de Freeling
y tiene las posiciones de inicio y fin marcadas.
El primer componente de la tupla resultado, tag, es un string que puede tomar los
siguientes valores:
        * B_EVENTO, I_EVENTO
        * B_INDICE, I_INDICE
        * INTRUSO
        * O

</pre>
  <dl class="fields">
  </dl>
</td></tr></table>
</div>
<br />
<!-- ==================== NAVIGATION BAR ==================== -->
<table class="navbar" border="0" width="100%" cellpadding="0"
       bgcolor="#a0c0ff" cellspacing="0">
  <tr valign="middle">

  <!-- Tree link -->
      <th>&nbsp;&nbsp;&nbsp;<a
        href="module-tree.html">Trees</a>&nbsp;&nbsp;&nbsp;</th>

  <!-- Index link -->
      <th>&nbsp;&nbsp;&nbsp;<a
        href="identifier-index.html">Indices</a>&nbsp;&nbsp;&nbsp;</th>

  <!-- Help link -->
      <th>&nbsp;&nbsp;&nbsp;<a
        href="help.html">Help</a>&nbsp;&nbsp;&nbsp;</th>

  <!-- Project homepage -->
      <th class="navbar" align="right" width="100%">
        <table border="0" cellpadding="0" cellspacing="0">
          <tr><th class="navbar" align="center"
            >alan</th>
          </tr></table></th>
  </tr>
</table>
<table border="0" cellpadding="0" cellspacing="0" width="100%%">
  <tr>
    <td align="left" class="footer">
    Generated by Epydoc 3.0.1 on Thu Oct 21 00:21:14 2010
    </td>
    <td align="right" class="footer">
      <a target="mainFrame" href="http://epydoc.sourceforge.net"
        >http://epydoc.sourceforge.net</a>
    </td>
  </tr>
</table>

<script type="text/javascript">
  <!--
  // Private objects are initially displayed (because if
  // javascript is turned off then we want them to be
  // visible); but by default, we want to hide them.  So hide
  // them unless we have a cookie that says to show them.
  checkCookie();
  // -->
</script>
</body>
</html>
